{% extends "Common/AdminBase.html" %}
{% load filters %} 
{% block Location %}

<li class="current">栏目管理</li>
<script>
//设置当前导航
Nav_Page="ArticleType";
</script>

{% endblock %}


{% block content %}

  <script type="text/javascript" src='/site_media/admin/scripts/jquery.dragsort-0.5.1.min.js'></script>


<div class="contentcontainer">
	

	
	 
	
	
            <div class="headings altheading">
                <h2>栏目管理</h2>
            </div>
            <div class="contentbox">
            	<table width="100%">
                	<thead>
                    	<tr>
                        	<th>标题</th>
                            <th>默认模版</th>
                            <th>操作</th>
                       
                        </tr>
                    </thead>
                    <tbody id="typebody">
                    
                        <tr >
                        	<td>顶级类别</td>
                            <td> -- </td>
                            <td>
                            	
                                <a href="#" dataType="DialogAjax" dataval="/AdminMain/ArticleType/Add/" alt="添加分类"  >添加下级</a>
                            </td>
                   
                        </tr>
                            {% for info in Model   %}
                       <tr >
                        	<td>                     
                        	 {% for key in info.Path|split:'/' %}
                        	 	{% ifequal  info.SuperiorId '-1' %}  
                        	 &nbsp;&nbsp;&nbsp;
							 	{% else  %}
							  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
							  	{% endifequal  %}
							 
                        	{% endfor  %}
                        	
                        	 {{info.Title}}</td>
                            <td> {{info.TemplateId.TemplateName}} </td>
                            <td>
                            	<a href="#" dataType="DialogAjax" dataval="/AdminMain/ArticleType/Edit/?id={{info.ArticleTypeid}}" alt="编辑分类" >编辑</a>
                            	<a href="#" dataType="confimsubmit" datareturn="onRefresh"   dataval="/AdminMain/ArticleType/DoDel/?Id={{info.ArticleTypeid}}" dataTip="你确定[删除]该分类?" >删除</a>
                                <a href="#" dataType="DialogAjax" dataval="/AdminMain/ArticleType/Add/?SuperiorId={{info.ArticleTypeid}}" alt="添加分类" >添加下级</a>
                            </td>
                   
                        </tr>
                       	{% endfor  %}
                       <script>
function onRefresh()
{
$.tips("操作成功",null,2,function(){
window.location=window.location;
});
}



</script>
                    </tbody>
                </table>
               
                <div style="clear: both;"></div>
            </div>
            
        </div>
{% endblock %}



